-- GENERATED SPELL FOR [Riverpaw Herbalist] --


function spell0_501(pUnit, Event) --@Drink Minor Potion,Self--
pUnit:FullCastSpellOnTarget(3368,pUnit)
pUnit:RegisterEvent('Sorts_501', 3000, 1)
end

function spell1_501(pUnit, Event) --@Potion Strength II,Self--
pUnit:FullCastSpellOnTarget(3369,pUnit)
pUnit:RegisterEvent('Sorts_501', 630, 1)
end

function Sorts_501(pUnit, Event)
local choix_sorts_501 = math.random(0, 1)
if choix_sorts_501 == 0 then
pUnit:RegisterEvent('spell0_501', 1, 1)
end
if choix_sorts_501 == 1 then
pUnit:RegisterEvent('spell1_501', 1, 1)
end
end

function mob501_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_501', math.random(1500, 3000), 1)
end

function mob501_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob501_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob501_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(501, 1, 'mob501_Action')
RegisterUnitEvent(501, 2, 'mob501_Leave')
RegisterUnitEvent(501, 3, 'mob501_Kill')
RegisterUnitEvent(501, 4, 'mob501_Die')
